package com.aguo.wxpush.constant;

import com.alibaba.fastjson.JSONArray;
import lombok.Data;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;
import org.springframework.stereotype.Component;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.Map;

/**
 * @Author: wenqiaogang
 * @DateTime: 2022/8/23 12:51
 * @Description: TODO
 */
@Component
@ConfigurationProperties(prefix = "wx.config")
@Data
public class ConfigConstant {
    @Value("${wx.config.appId}")
    public String appId;

    @Value("${wx.config.appSecret}")
    public String appSecret;
    @Value("${wx.config.templateId}")
    public String templateId;

    public String city;
    public ArrayList<String> openidList;


    @Value("${weather.config.key}")
    public String weatherKey;
    @Value("${weather.config.adCode}")
    public String weatherAdCode;
    @Value("${weather.config.output}")
    public String weatherOutput;
    @Value("${weather.config.extensions}")
    public String weatherExtensions;

    @Value("${weather.config.appId}")
    public String weatherAppId;
    @Value("${weather.config.appSecret}")
    public String weatherAppSecret;

    @Value("${message.config.togetherDate}")
    public String togetherDate;
    @Value("${message.config.birthday1}")
    public String birthday1;
    @Value("${message.config.birthday2}")
    public String birthday2;
    @Value("${message.config.message}")
    public String message;


    @Value("${ApiSpace.enableDaily}")
    private boolean enableDaily = true;
    @Value("${ApiSpace.token}")
    public String token;

    public Map<String, JSONArray> map = new HashMap<>();
    public JSONArray jsonArray = new JSONArray();

    public boolean isEnableDaily() {
        return enableDaily;
    }


}
